//
//  YDBaseViewController.h
//  IngCard
//
//  Created by kf on 2017/7/10.
//  Copyright © 2017年 IngDan. All rights reserved.
//

#import <UIKit/UIKit.h>
//#import "QMUINavigationController.h"

@class QMUINavigationTitleView;
@class QMUIEmptyView;


@protocol YDViewControllerProtocol <NSObject>
@optional
-(void) didInitialized;
-(void) initNBandSB;
-(void) initSubviews; //在ViewDidLoad中调用
-(void) initDataSource; //在ViewDidAppear中调用
@end

@interface YDBaseViewController : UIViewController<YDViewControllerProtocol>

@property(nonatomic,strong,readonly) QMUINavigationTitleView *titleView;

@property(nonatomic, assign) UIInterfaceOrientationMask supportedOrientationMask;

@property(nonatomic, strong) NSMutableArray<NSURLSessionTask*> *currentTasks;

@property(nonatomic,assign,readonly,getter = isEmptyViewShowing) BOOL emptyViewShowing;

- (void)showDebugInfo;
- (void)showEmptyView;
- (void)showEmptyViewWithLoading;
- (void)showEmptyViewWithText:(NSString *)text
                   detailText:(NSString *)detailText
                  buttonTitle:(NSString *)buttonTitle
                 buttonAction:(SEL)action;
- (void)showEmptyViewWithImage:(UIImage *)image
                          text:(NSString *)text
                    detailText:(NSString *)detailText
                   buttonTitle:(NSString *)buttonTitle
                  buttonAction:(SEL)action;
- (void)showEmptyViewWithLoading:(BOOL)showLoading
                           image:(UIImage *)image
                            text:(NSString *)text
                      detailText:(NSString *)detailText
                     buttonTitle:(NSString *)buttonTitle
                    buttonAction:(SEL)action;
- (void)hideEmptyView;
@end



